﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Automted_Bank_teller
{
    public partial class ClientsFunction : Form
    {
        public ClientsFunction()
        {
            InitializeComponent();
        }

        private void label_welcomeName_Click(object sender, EventArgs e)
        {

        }

        private void BTN_Clnt_fun_withdrawls_Click(object sender, EventArgs e)
        {
            WithdrawlsForm clnt_withdrawls = new WithdrawlsForm();
            clnt_withdrawls.ShowDialog();
        }

        private void BTN_Clnt_fun_Deposite_Click(object sender, EventArgs e)
        {
            DepositeForm clnt_deposite = new DepositeForm();
            clnt_deposite.ShowDialog();
        }

        private void BTN_Clnt_fun_EditProfile_Click(object sender, EventArgs e)
        {
            ClientProfile profile = new ClientProfile();
            profile.ShowDialog();
        }

        private void BTN_Clnt_fun_payBills_Click(object sender, EventArgs e)
        {
            Bank_Entry_System main_entry = new Bank_Entry_System();
            main_entry.Close();
            main_entry.Hide();

            PayBills bill = new PayBills();
            bill.ShowDialog();

        }

        private void ClientsFunction_Load(object sender, EventArgs e)
        {
            Timer_clnt_Fun.Start();
            label_welcomeName.Text = "Welecome: " + global_var.G_Client_ID;

        }

        private void Timer_clnt_Fun_Tick(object sender, EventArgs e)
        {
            label_client_fun_timeDate.Text = (DateTime.Now.ToString("hh:mm:ss tt|"));
        }

        private void BTN_Clnt_fun_Logout_Click(object sender, EventArgs e)
        {
            DialogResult dialog = MessageBox.Show("Do you want to Logout?", "Logout", MessageBoxButtons.OK);

            if (dialog == DialogResult.OK)
            {
                this.Close();
                this.Hide();
                
                Bank_Entry_System main_entry = new Bank_Entry_System();
                main_entry.ShowDialog();
            }
        }

        private void BTN_Clnt_fun_FeedBack_Click(object sender, EventArgs e)
        {
            FeedBack feeds = new FeedBack();
            feeds.ShowDialog();
        }
    }
}
